using System;

namespace Deepcode.Flux.Core.Extensions
{
	/// <summary>
	/// Specifies that an array field should be loaded from an
	/// xml attribute, with it's value seperated by comma.
	/// </summary>
	[AttributeUsage(AttributeTargets.Field, Inherited=true)]
	public class XmlCodonArrayAttribute : Attribute
	{
		private string	_Name;
		private bool	_IsRequired;
		
		public XmlCodonArrayAttribute(string name)
		{
			_Name = name;
			_IsRequired = false;
		}

		public string Name 
		{
			get{ return _Name; }
			set{ _Name = value; }
		}

		public bool IsRequired
		{
			get{ return _IsRequired; }
			set{ _IsRequired = value; }
		}
	}
}
